
import { Pagination } from 'antd';

interface MyProps{
    currentPage:number,
    pageSize:number,
    total:number,
    getCurrent(data:number):void
}



const MyPage = (props:MyProps) => {
    const { currentPage , pageSize , total , getCurrent} = props;
    const changePage = (page:number , pageSize:number) => {
        getCurrent(page)
    }
    return (
        <div>
            <Pagination current={currentPage} total={total} pageSize={pageSize} onChange={changePage} />
        </div>
    )
};


export default MyPage;


